package de.unimannheim.ki.databaseentities;

import java.io.Serializable;
import javax.persistence.*;

import java.util.List;


/**
 * The persistent class for the song database table.
 * 
 */
@Entity
public class Song implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id 
	private String id;

	private String genre;

	private String interpret;

	private String name;

	//bi-directional many-to-many association to Musicuser
	@ManyToMany(mappedBy="songs", cascade= CascadeType.PERSIST)
	private List<Musicuser> musicusers;

	public Song() {
	}

	public String getId() {
		return this.id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getGenre() {
		return this.genre;
	}

	public void setGenre(String genre) {
		this.genre = genre;
	}

	public String getInterpret() {
		return this.interpret;
	}

	public void setInterpret(String interpret) {
		this.interpret = interpret;
	}

	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public List<Musicuser> getMusicusers() {
		return this.musicusers;
	}

	public void setMusicusers(List<Musicuser> musicusers) {
		this.musicusers = musicusers;
	}

}